//------------------------------------------------------------------------------
// <copyright file="Tavern.cs" company="Damian Antonowicz">
//       copyright © 2010 Damian Antonowicz
// </copyright>
// <author>Damian Antonowicz</author>
// <email>poczta@damianantonowicz.pl</email>
//------------------------------------------------------------------------------

using System;

namespace DotBeer.Business.Entities
{
    public class Tavern : TavernHero, ICloneable
    {
        int _position;
        Side _side;

        public int Position
        {
            get { return _position; }
            set
            {
                _position = value;
                OnPropertyChanged("Position");
            }
        }

        public Side Side
        {
            get { return _side; }
            set
            {
                _side = value;
                OnPropertyChanged("Side");
            }
        }

        public Tavern()
        {
        }

        public override string ToString()
        {
            return String.Format("{0}, {1}", name, _side.ToString());
        }

        #region ICloneable Members

        object ICloneable.Clone()
        {
            return this.Clone();
        }

        public Tavern Clone()
        {
            return new Tavern()
                        {
                            Name = name,
                            Position = _position,
                            Side = _side
                        };
        }

        #endregion
    }
}
